Skip to content

Instantly share code, notes, and snippets.

@NaniteFactory
NaniteFactory / setcookie.go
Created October 21, 2019 06:30
chromedp set-cookie example
package main
import (
"context"
"fmt"
"log"
"time"
"github.com/chromedp/cdproto/cdp"
"github.com/chromedp/cdproto/network"
@lopspower
lopspower / README.md
Last active January 28, 2026 17:16
Hexadecimal color code for transparency

Hexadecimal color code for transparency

Twitter

How to set transparency with hex value ?

For example, you want to set 40% alpha transparence to #000000 (black color), you need to add 66 like this #66000000.

All hex value from 100% to 0% alpha:

@aravindanve
aravindanve / bypass-disable-devtool.md
Last active January 28, 2026 17:12
Bypass disable-devtool

(Working as of 2025-02-09)

There are websites that use disable-devtool to prevent you from opening or using devtools. They typically prevent you from right clicking or using the keyboard shortcut to open devtools. Even if you successfully do so, they detect it and redirect you elsewhere. You can bypass this by using one of the following ways.

Opening devtools

If the shortcut F12 on Windows or Option + ⌘ + I on Mac do not work. Press the three vertically aligned dots in the top right corner of your Google Chrome or Microsoft Edge window. Under the section "More Tools", you'll see the option to select "Developer Tools" which opens the toolkit in your window.

@shacharmirkin
shacharmirkin / vllm_on_google_colab.ipynb
Last active January 28, 2026 17:10
Serving an LLM with vLMM on Google Colab
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@thomaspeitz
thomaspeitz / gist:eaef87c714418eb1fe1a732655d4637b
Last active January 28, 2026 17:07
Karpenter EC2NodeClass aws mount nvme /var/lib/containerd
apiVersion: karpenter.k8s.aws/v1beta1
kind: EC2NodeClass
metadata:
name: gitlab-runner
spec:
amiFamily: AL2023
blockDeviceMappings: []
userData: |
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="BOUNDARY"
@rverchere
rverchere / kube-state-metrics-vpa.yaml
Last active January 28, 2026 17:06
kube-state-metrics configuration for VPA metrics
## Kube State Metrics to get VPA metrics
# Old vs New metrics:
# - kube_verticalpodautoscaler_labels -> kube_customresource_verticalpodautoscaler_labels
# - kube_verticalpodautoscaler_status_recommendation_containerrecommendations_target -> kube_customresource_verticalpodautoscaler_status_recommendation_containerrecommendations_target
# - kube_verticalpodautoscaler_status_recommendation_containerrecommendations_lowerbound -> kube_customresource_verticalpodautoscaler_status_recommendation_containerrecommendations_lowerbound
# - kube_verticalpodautoscaler_status_recommendation_containerrecommendations_upperbound -> kube_customresource_verticalpodautoscaler_status_recommendation_containerrecommendations_upperbound
# - kube_verticalpodautoscaler_status_recommendation_containerrecommendations_uncappedtarget -> kube_customresource_verticalpodautoscaler_status_recommendation_containerrecommendations_uncappedtarget
# Resources:
# - https://github.com/kubernetes/kube-state-metrics/blob/main/docs/customresourcestate-me
@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active January 28, 2026 17:16
Complete Recent Discord Quest

Complete Recent Discord Quest

Note

This does not works in browser for quests which require you to play a game! Use the desktop app to complete those.

How to use this script:

  1. Accept a quest under Discover -> Quests
  2. Press Ctrl+Shift+I to open DevTools
  3. Go to the Console tab
  4. Paste the following code and hit enter:

Interview Questions

Node.js

Q1: What do you mean by Asynchronous API? ☆☆

Answer: All APIs of Node.js library are aynchronous that is non-blocking. It essentially means a Node.js based server never waits for a API to return data. Server moves to next API after calling it and a notification mechanism of Events of Node.js helps server to get response from the previous API call.

Source: tutorialspoint.com

@Patras3
Patras3 / WeatherStationToHA.md
Created July 10, 2025 19:15
Vevor Wireless Weather Station 7-in-1 in Home Assistant via SDR and rtl_433 addons

Vevor Wireless Weather Station 7-in-1 with MQTT and Home Assistant

This guide shows how to connect a weather station (using rtl_433) to MQTT and auto-discover it in Home Assistant.


1. Add Required Add-ons

Go to:
Add-ons -> Store -> Repositories